package com.ali.ttt.analysis.entity;

import co.elastic.clients.json.JsonpDeserializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @Author : yuxl
 * @create 2024/7/17 5:38 PM
 */
@Data
@ApiModel(value = "访问操作记录")
@Document(indexName = "access_operate_record")
public class AccessOperateRecord{

    @Id
    @Field(type = FieldType.Keyword)
    private String id;

    @ApiModelProperty("name")
    @Field(type = FieldType.Keyword)
    private String name;

    @ApiModelProperty("content")
    @Field(type = FieldType.Text , analyzer = "ik_max_word")
    private String content;

    @ApiModelProperty("content")
    @Field(name = "c_time",type = FieldType.Date)
    private LocalDateTime cTime;


    @ApiModelProperty("user")
    @Field(type = FieldType.Nested)
    private AccessUser user;


}
